package lanqiaoMoNiC;

public class A {
	private static int count;

	public static void main(String[] args) {
		String x="10111000100110010111110111000101100100011001100110\r\n" + 
				"00100101100010100101101000101011101000011010010001\r\n" + 
				"10010001101100010001001111101000011001011011010110\r\n" + 
				"01011101011110101110101111010100010001111100000000\r\n" + 
				"11101110101100101100100101010011101101111110100101\r\n" + 
				"10010111000000101111100010011100100101110100101000\r\n" + 
				"10010001000110101011000011111001110110101010111101\r\n" + 
				"01101000100000111010001110001101111101000001000011\r\n" + 
				"01001010001011100100110010111111100110111100010000\r\n" + 
				"10000001011000000011000110110101010111100011000000\r\n" + 
				"11010100101101110000000110110011111000100010011110\r\n" + 
				"10101101101001011101100011011111111101100100010000\r\n" + 
				"00101000100000000101000100101011001111000100111011\r\n" + 
				"10100111011101100010101000111111001010000100111111\r\n" + 
				"01111010100001100010011011100010111001111001010001\r\n" + 
				"01100011100111000010100000011101100001001000010001\r\n" + 
				"00000001111001000111010010001101101110110110100000\r\n" + 
				"00000001110111101010011111110000110101100001111101\r\n" + 
				"11100100111110100101100110010111100011111011111000\r\n" + 
				"10010101101111011011011111101000111011000010111001";
                char[] q=x.toCharArray();
                for (int i = 0; i < q.length; i++) {
					if (q[i]=='1') {
						count++;
					}
				}
                System.out.println(count);
	}

}
